package com.zhiyou100.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.servlet.http.HttpSession;

@Controller
public class ExitController {

    @RequestMapping("/exit")
    public String exit(HttpSession session) {
        session.invalidate();
        System.out.println("-->日志 注销session域   退出登录");
        return "forward:/index.jsp";
    }
}
